package com.edu.compile.template.ftl.block;

import com.edu.compile.template.model.IfTrueConfig;
import com.edu.compile.template.ftl.BranchNodeBlockParse;

import java.util.ArrayList;
import java.util.List;

public class Switch extends BranchNodeBlockParse {

    public Switch(String nodeId, String nodeType, String nodeName, String parentNodeId) {
        super(nodeId, nodeType, nodeName, parentNodeId);
    }

    private List<IfTrueConfig> elseIfList;

    private IfTrueConfig alwaysTrue;

    private List<String> undefinedCheckList = new ArrayList<>();

    public void addUndefinedCheck(String param) {
        undefinedCheckList.add(param);
    }

    public List<String> getUndefinedCheckList() {
        return undefinedCheckList;
    }

    public List<IfTrueConfig> getElseIfList() {
        return elseIfList;
    }

    public void setElseIfList(List<IfTrueConfig> elseIfList) {
        this.elseIfList = elseIfList;
    }

    public IfTrueConfig getAlwaysTrue() {
        return alwaysTrue;
    }

    public void setAlwaysTrue(IfTrueConfig alwaysTrue) {
        this.alwaysTrue = alwaysTrue;
    }
}
